import Vue from 'vue'
import axios from 'axios'

import App from './App'
import router from './router'
import store from './store'

import ElementUI from 'element-ui'
import '@/assets/scss/theme.scss'
import '@/assets/css/flex.css'
import '@/assets/css/grid.css'

import filters from './filters'

Object.keys(filters).forEach(key => {
  Vue.filter(key, filters[key])
})


if (!process.env.IS_WEB) Vue.use(require('vue-electron'))
Vue.http = Vue.prototype.$http = axios
Vue.config.productionTip = false

Vue.use(ElementUI)

/* eslint-disable no-new */
new Vue({
  components: { App },
  router,
  store,
  template: '<App/>'
}).$mount('#app')
